package com.raycloud.action.common;

import java.util.Map;

import org.apache.struts2.interceptor.ApplicationAware;
import org.apache.struts2.interceptor.RequestAware;
import org.apache.struts2.interceptor.SessionAware;

import com.opensymphony.xwork2.ActionSupport;

/**
 * 此为测试demo为了方便所有作用域对象每个Action都注入，但是真实项目中不建议这么写。因为注入越多东西相应的效率会越低
 * 并且并不是每一个action中都会用到这三个作用域对象
 * @author wangyi
 *
 */
public class BaseAction extends ActionSupport implements RequestAware, SessionAware, ApplicationAware{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	protected Map<String, Object> application;
	protected Map<String, Object> session;
	protected Map<String, Object> request;

	public void setApplication(Map<String, Object> application) {
		this.application = application;
	}

	public void setSession(Map<String, Object> session) {
		this.session = session;
	}

	public void setRequest(Map<String, Object> request) {
		this.request = request;
	}
	
}
